package com.suse.result;

import lombok.Getter;
import lombok.ToString;

/**
 * 响应结果状态信息枚举类
 */
@Getter
@ToString
public enum ResultEnum {

    RESULT_OPERATION_SUCCESS(true,"操作成功"),

    RESULT_PHONE_ILLEGAL(false,"手机号不合法"),
    RESULT_CODE_ERROR(false,"验证码错误"),
    RESULT_SHOP_NOT_FOUND(false,"商户信息不存在"),
    RESULT_SHOP_TYPE_NOT_FOUND(false,"商户类型不存在"),

    RESULT_FILE_NAME_ERROR(false,"错误的文件名称"),

    RESULT_FUNCTION_NOT_FINISH(false,"功能未完成"),
    RESULT_SERVER_EXCEPTION(false,"服务器异常"),

    SECKILL_NOT_START(false,"秒杀未开始！"),
    SECKILL_OVER(false,"秒杀已结束！"),
    SECKILLED(false,"您已秒杀过，不能重复秒杀！"),
    STOCK_EMPTY(false,"库存不足！"),
    SECKILL_FAIL(false,"秒杀失败，请重试！"),
    NO_SECKILL_QUALIFICATION(false,"秒杀失败，没有秒杀资格！"),

    RESULT_OPERATION_FAIL(false, "操作失败");



    private final boolean success;
    private final String message;

    ResultEnum(boolean success, String message) {
        this.success = success;
        this.message = message;
    }

}
